<% add_decidim_page_title(t(".introduce_user_data")) %>

<div class="item_show__header">
  <h1 class="item_show__header-title">
    <%= t(".introduce_user_data") %>
    <%= link_to t(".reject"), pending_authorization_rejection_path(@pending_authorization), method: :post, class: "button button__sm button__secondary alert button--title destroy" %>
  </h1>
</div>

<div class="item__edit item__edit-1col">
  <div class="item__edit-form">
    <%= decidim_form_for(@form, url: pending_authorization_confirmation_path(@pending_authorization),
                                html: { class: "form form-defaults" }) do |form| %>
      <div class="form__wrapper">
        <div class="card">
          <div class="card-divider"></div>

          <div class="card-section">
            <div class="row column">
              <%= image_tag @pending_authorization.attached_uploader(:verification_attachment).variant_url(:big), class: "thumbnail" %>
            </div>

            <div class="row column">
              <%= form.select :document_type, @form.document_types_for_select, prompt: true, selected: nil %>
            </div>

            <div class="row column">
              <%= form.text_field :document_number, value: nil %>
            </div>

            <%= form.hidden_field :verification_type, value: :online %>
          </div>
        </div>
      </div>

      <div class="item__edit-sticky">
        <div class="item__edit-sticky-container">
          <%= form.submit t(".verify"), class: "button button__sm button__secondary" %>
        </div>
      </div>
    <% end %>
  </div>
</div>
